﻿using BCCommon;
using System.ComponentModel.DataAnnotations;

namespace BCDto.Location.Driver
{
    /// <summary>
    /// 司机位置信息
    /// </summary>
    public class DriverLocationRequestDto
    {
        /// <summary>
        /// 所在位置精度
        /// </summary>
        [Display(Name = "所在位置精度")]
        [Required(ErrorMessage = "{0} 不能为空")]
        public double Longitude { get; set; }

        /// <summary>
        /// 所在位置纬度
        /// </summary>
        [Display(Name = "所在位置纬度")]
        [Required(ErrorMessage = "{0} 不能为空")]
        public double Latitude { get; set; }

        /// <summary>
        /// 区域编码
        /// </summary>
        [Display(Name = "区域编码")]
        [Required(ErrorMessage = "{0} 不能为空")]
        [StringLength(6, ErrorMessage = "{0}长度最大为 {1} 位")]
        [RegularExpression(RegexPatterns.NUMBER, ErrorMessage = "{0} 应全部是数字")]
        public string ZoneCode { get; set; }
        
    }
}
